package XMLread;

import java.util.ArrayList;

/**
 * This object represents a hallway in a floor of a building.
 */
public class Hallway {
	private String hallwayID;
	private ArrayList<Object> entities;
	
	/**
	 * Constructor for this hallway object.
	 */
	public Hallway(){
		hallwayID = "";
		entities = new ArrayList<Object>();
	}
	
	/**
	 * Constructor for this hallway object.
	 * @param id the id of this hallway.
	 */
	public Hallway(String id){
		hallwayID = id;
		entities = new ArrayList<Object>();
	}
	
	/**
	 * Returns the ID of this intersection.
	 * @return the ID of this intersection.
	 */
	public String getHallwayID(){
		return hallwayID;
	}
	
	/**
	 * Sets the ID of this intersection.
	 * @param the new ID of this intersection.
	 */
	public void setHallwayID(String id){
		hallwayID = id;
	}
	
	/**
	 * Adds a given object to this hallway.
	 * @param o the object being added.
	 */
	public void addEntity(Object o){
		entities.add(o);
	}
	
	/**
	 * Returns the list of entities that make up this hallyway.
	 * @return the arraylist of objects that constitute this hallway.
	 */
	public ArrayList<Object> getEntities(){
		return entities;
	}
}
